

function setup() {
	if (navigator.geolocation) {
		navigator.geolocation.getCurrentPosition(local);
	}
	
	var days = new Array()
	days[0] = "Sunday";
	days[1] = "Monday";
	days[2] = "Tuesday";
	days[3] = "Wednesday";
	days[4] = "Thursday";
	days[5] = "Friday";
	days[6] = "Saturday";
	
	d = new Date();
	document.getElementById("date").value = days[d.getDay()]+", hour = "+d.getHours();
}

function local(position) {
	document.getElementById("localized").className = "show";
	document.getElementById("lon").value = position.coords.longitude;
	document.getElementById("lat").value = position.coords.latitude;
}

function hideshow() {
	var e = document.getElementById("adv_params");
	if(e.className == "hide")
		e.className = "show";
	else
		e.className = "hide";
}